/** 
 * projectName:  
 * fileName:  
 * packageName:  
 * date: 
 * copyright(c) 2017-2020 xxx公司
 */
package cn.merchant.service;

import cn.itcast.pojo.*;

import java.util.List;
import java.util.Map;


/**
 * @title: userService.java 
 * @package com.job.service 
 * @description: TODO
 * @author: 欧阳辉
 * @date: 2019年1月25日 下午3:17:36 
 * @version: V1.0   
*/
public interface merchantService {

	Map<String,Object> login(String username, String password);

	boolean acceptOrder(Integer orderId);

	packageOrder findOneOrder(String orderId);

    boolean abnormalOrder(Integer orderId, String explain);

    boolean updateUserInfo(merchant merchant);

	boolean updateOrder(packageOrder packageOrder);

	boolean addImgPath(String path, Integer id);

    boolean updateOrderItem(packageOrderItem packageOrderItem, Integer orderId);

	boolean addOrderItem(Integer orderId, Integer classifyId);

	boolean delectOrderItem(Integer orderId);

    boolean createAccount(account account);

    boolean toPayByOrder(Integer orderId, String openId);

	merchant findUserInfo(String openId);

    boolean toLatAndLon(String lat, String lon, String openId);

	merchant findHoresmanArea(String openId);

    boolean cancelOrder(Integer orderId);

	List<account> findMerchantAccount(String openId);

	List<recharge> findrechargeRecord(String openId);

	List<withdraw> findWithdrawRecord(String openId);

    List<packageOrder> findMerchantOrder(String orderStatus, String openId);

	boolean addRecharge(recharge recharge);

	boolean updateRecharge(recharge recharge);

	List<List<order>> findHoresmanOverOrder(String openId);

	List<horseman> findHoresman(String openId);

    boolean finishOrder(Integer orderId, String openId);

    Map<String, List<Map<String, String>>> findChildrenMerchant(String openId);

    boolean registMerchant(String phone, String password, String name, int code,String receivingtype,String merchantLat,String merchantLon);

	boolean updatePassword(String password, String passwordOld, String openId);

	//查询门店信息经度纬度
	List<merchant>selectLatLon();

	boolean updatachantmessage(merchant merchant);

	merchant selectidmerchant(String opnid);

	List<order>merchantlist(String merchantopenid);

	//商户端修改订单
	int updatemerchanttype(String ordernumber,String payproducttype);

	//查询订单信息
	order merchantpayuser(Integer id);

	//查询个人,商户金额通用
	account accountmoney(String openid);

	//修改账户
	int accountupdatemoney(account account);

	//修改订单状态已完成
	int orderupdate(order order);

	//修改记录
	int addaccount(account account);

	//新增消费记录
	int addearnings(earnings earnings);

	merchant selectopenidmerchat(String openid);

	//用户取消门店回收订单
	boolean cancelmerchaent(String orderid);
}
